package com.ruoyi.ap.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.ap.mapper.OrderDetailMapper;
import com.ruoyi.ap.domain.OrderDetail;
import com.ruoyi.ap.service.IOrderDetailService;

/**
 * 销售产品清单Service业务层处理
 * 
 * @author HuaQP
 * @date 2023-09-15
 */
@Service
public class OrderDetailServiceImpl implements IOrderDetailService 
{
    @Autowired
    private OrderDetailMapper orderDetailMapper;

    /**
     * 查询销售产品清单
     * 
     * @param id 销售产品清单主键
     * @return 销售产品清单
     */
    @Override
    public OrderDetail selectOrderDetailById(Long id)
    {
        return orderDetailMapper.selectOrderDetailById(id);
    }

    /**
     * 查询销售产品清单列表
     * 
     * @param orderDetail 销售产品清单
     * @return 销售产品清单
     */
    @Override
    public List<OrderDetail> selectOrderDetailList(OrderDetail orderDetail)
    {
        return orderDetailMapper.selectOrderDetailList(orderDetail);
    }

    /**
     * 新增销售产品清单
     * 
     * @param orderDetail 销售产品清单
     * @return 结果
     */
    @Override
    public int insertOrderDetail(OrderDetail orderDetail)
    {
        return orderDetailMapper.insertOrderDetail(orderDetail);
    }

    /**
     * 修改销售产品清单
     * 
     * @param orderDetail 销售产品清单
     * @return 结果
     */
    @Override
    public int updateOrderDetail(OrderDetail orderDetail)
    {
        return orderDetailMapper.updateOrderDetail(orderDetail);
    }

    /**
     * 批量删除销售产品清单
     * 
     * @param ids 需要删除的销售产品清单主键
     * @return 结果
     */
    @Override
    public int deleteOrderDetailByIds(Long[] ids)
    {
        return orderDetailMapper.deleteOrderDetailByIds(ids);
    }

    /**
     * 删除销售产品清单信息
     * 
     * @param id 销售产品清单主键
     * @return 结果
     */
    @Override
    public int deleteOrderDetailById(Long id)
    {
        return orderDetailMapper.deleteOrderDetailById(id);
    }
}
